package cn.erbudev;

import java.util.Map;

import cn.erbudev.CommunicableThread.Condition;


public abstract class DistributedTask implements java.io.Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	protected Long sendThreadID; // 谁发来的
	protected Long targetThreadID; // 谁来处理
	protected Map<String, Object> data;
	protected boolean isFinish;

	public DistributedTask(Long sendThreadID, Long targetThreadID, Map<String, Object> data) {
		super();
		this.sendThreadID = sendThreadID;
		this.targetThreadID = targetThreadID;
		this.data = data;
	}

	public abstract DistributedTask compute(Condition running);
}
